import 'package:flutter/cupertino.dart';
import 'package:get/get.dart';

class ShopCarController extends GetxController{
  late TextEditingController controller = TextEditingController();

  ///创建输入内容Controller
  RxList controllers = <TextEditingController>[].obs;

  var data = <Map>[].obs;

  ///勾选或者取消勾选
  void selectCheck(Map mapData){
    if(data.map((element) => element["id"]).toList().contains(mapData["id"])){
      data.remove(mapData);
    }else{
      data.add(mapData);
    }
  }

  ///商品勾选
  void goodsCheck(int index){

  }

}